package cn.choujay.tlias.mapper;


import cn.choujay.tlias.domain.Dept;
import cn.choujay.tlias.domain.Emp;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.context.annotation.Bean;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @author Ye
 * @description 针对表【dept(部门表)】的数据库操作Mapper
 * @createDate 2023-05-20 20:52:38
 * @Entity cn.choujay.tlias.domain.Dept
 */
@Mapper
public interface DeptMapper {
    List<Dept> getAllDept();

    Boolean addDept(Emp emp);

    @Transactional(propagation = Propagation.REQUIRES_NEW)
    Boolean deleteDept(@Param("ids") Integer[] ids);

    Boolean updateDeptById(Emp emp);


}
